
#ifndef BULLETMANAGER_H
#define BULLETMANAGER_H

#include "Entity.h"
#include "framework.h"
#include "EntityMesh.h"
#include <list>
#pragma once

class Bullet : public Entity {

public:
	Vector3 speed;
	bool isActive;
	float timeLeft;
	Bullet();
	~Bullet();
	void render();
	void update(float dt);
	bool collides(EntityMesh* ent);
};

class BulletManager
{
private:

	BulletManager(void);
	~BulletManager(void);

public:

	std::list<Bullet*> bullets;



	void shootBullet(Matrix44 m, Vector3 speed);

	void update(float dt);

	void render();

	int collides(EntityMesh* ent);

	static BulletManager* instance;

	static BulletManager* getInstance();
};

#endif
